package com.atguigu.ssyx.activity.mapper;

import com.atguigu.ssyx.model.activity.CouponInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
* @author LiJun
* @description 针对表【coupon_info(优惠券信息)】的数据库操作Mapper
* @createDate 2025-05-11 20:52:31
* @Entity com.atguigu.ssyx.activity.CouponInfo
*/
@Repository
public interface CouponInfoMapper extends BaseMapper<CouponInfo> {

    /**
     * sku优惠券
     * @param skuId
     * @param categoryId
     * @param userId
     * @return
     */
    List<CouponInfo> selectCouponInfoList(@Param("skuId") Long skuId, @Param("categoryId") Long categoryId, @Param("userId") Long userId);

    /**
     * 获取用户全部优惠券
     * @param userId
     * @return
     */
    List<CouponInfo> selectCartCouponInfoList(@Param("userId")Long userId);
}




